#include "oj_model.hpp"
using namespace ns_model;
void testModel()
{
    Model model;
    std::cout << model.LoadQuestionList(questions_list) << std::endl;
    std::vector<Question> out;
    std::cout << model.GetAllQuestions(out) << std::endl;
    for (const auto &e : out)
    {
        std::cout << e._id << std::endl;
        std::cout << e._title << std::endl;
        std::cout << e._difficulty << std::endl;
        std::cout << e._cpu_limit << std::endl;
        std::cout << e._mem_limit << std::endl;
        std::cout << e._desc << std::endl;
        std::cout << e._header << std::endl;
        std::cout << e._tail << std::endl;
    }
    Question oout;
    std::cout << model.GetOneQuestion(1, oout) << std::endl;
    std::cout << oout._id << std::endl;
    std::cout << oout._title << std::endl;
    std::cout << oout._difficulty << std::endl;
    std::cout << oout._cpu_limit << std::endl;
    std::cout << oout._mem_limit << std::endl;
    std::cout << oout._desc << std::endl;
    std::cout << oout._header << std::endl;
    std::cout << oout._tail << std::endl;
}
int main()
{
    testModel();
}